package com.shensi.appCollect.dao;


import com.shensi.appCollect.pojo.PayWay;
import com.shensi.appCollect.pojo.TradePaymentRecordsDO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 
 * @author chglee
 * @email 1992lcg@163.com
 * @date 2023-06-20 11:54:08
 */
@Mapper
public interface TradePaymentRecordsDao {

	TradePaymentRecordsDO get(Integer id);
	
	List<TradePaymentRecordsDO> list(Map<String,Object> map);
	
	int count(Map<String,Object> map);
	
	int save(TradePaymentRecordsDO tradePaymentRecords);
	
	int update(TradePaymentRecordsDO tradePaymentRecords);
	
	int remove(Integer id);
	
	int batchRemove(Integer[] ids);
	
	/**
	 * 使用enterpriseId查询商户编号
	 */
	List<PayWay> selectPayWayEnterpriseId(@Param("enterpriseId")Integer enterpriseId,@Param("mno")String mno);
	
	/**
	 * 订单号查询订单一条记录
	 * @param ordNo
	 * @return
	 */
	TradePaymentRecordsDO selectOneOrdNo(@Param("ordNo")String ordNo);
	/**
	 * 订单号查询订单一条记录
	 * @param ordNo
	 * @return
	 */
	TradePaymentRecordsDO selectorderSn(@Param("orderSn")String orderSn);
	
	/**
	 *更新订单支付状态
	 * @param ordNo
	 * @param status
	 * @return
	 */
	int updateOrdNoStatus(@Param("ordNo")String ordNo,@Param("status")Integer status);
	
}
